3.2.66 \(\int \frac {(1-a^2 x^2) \tanh ^{-1}(a x)}{x} \, dx\) [166]

Optimal. Leaf size=48 \[ -\frac {a x}{2}+\frac {1}{2} \tanh ^{-1}(a x)-\frac {1}{2} a^2 x^2 \tanh ^{-1}(a x)-\frac {1}{2} \text {PolyLog}(2,-a x)+\frac {1}{2} \text {PolyLog}(2,a x) \]

[Out]

-1/2*a*x+1/2*arctanh(a*x)-1/2*a^2*x^2*arctanh(a*x)-1/2*polylog(2,-a*x)+1/2*polylog(2,a*x)

________________________________________________________________________________________

Rubi [A]
time = 0.03, antiderivative size = 48, normalized size of antiderivative = 1.00, number of steps used = 5, number of rules used = 5, integrand size = 18, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.278, Rules used = {6161, 6031, 6037, 327, 212} \begin {gather*} -\frac {1}{2} a^2 x^2 \tanh ^{-1}(a x)-\frac {\text {Li}_2(-a x)}{2}+\frac {\text {Li}_2(a x)}{2}-\frac {a x}{2}+\frac {1}{2} \tanh ^{-1}(a x) \end {gather*}

Antiderivative was successfully verified.

[In]

Int[((1 - a^2*x^2)*ArcTanh[a*x])/x,x]

[Out]

-1/2*(a*x) + ArcTanh[a*x]/2 - (a^2*x^2*ArcTanh[a*x])/2 - PolyLog[2, -(a*x)]/2 + PolyLog[2, a*x]/2

Rule 212

Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(1/(Rt[a, 2]*Rt[-b, 2]))*ArcTanh[Rt[-b, 2]*(x/Rt[a, 2])], x]
 /; FreeQ[{a, b}, x] && NegQ[a/b] && (GtQ[a, 0] || LtQ[b, 0])

Rule 327

Int[((c_.)*(x_))^(m_)*((a_) + (b_.)*(x_)^(n_))^(p_), x_Symbol] :> Simp[c^(n - 1)*(c*x)^(m - n + 1)*((a + b*x^n
)^(p + 1)/(b*(m + n*p + 1))), x] - Dist[a*c^n*((m - n + 1)/(b*(m + n*p + 1))), Int[(c*x)^(m - n)*(a + b*x^n)^p
, x], x] /; FreeQ[{a, b, c, p}, x] && IGtQ[n, 0] && GtQ[m, n - 1] && NeQ[m + n*p + 1, 0] && IntBinomialQ[a, b,
 c, n, m, p, x]

Rule 6031

Int[((a_.) + ArcTanh[(c_.)*(x_)]*(b_.))/(x_), x_Symbol] :> Simp[a*Log[x], x] + (-Simp[(b/2)*PolyLog[2, (-c)*x]
, x] + Simp[(b/2)*PolyLog[2, c*x], x]) /; FreeQ[{a, b, c}, x]

Rule 6037

Int[((a_.) + ArcTanh[(c_.)*(x_)^(n_.)]*(b_.))^(p_.)*(x_)^(m_.), x_Symbol] :> Simp[x^(m + 1)*((a + b*ArcTanh[c*
x^n])^p/(m + 1)), x] - Dist[b*c*n*(p/(m + 1)), Int[x^(m + n)*((a + b*ArcTanh[c*x^n])^(p - 1)/(1 - c^2*x^(2*n))
), x], x] /; FreeQ[{a, b, c, m, n}, x] && IGtQ[p, 0] && (EqQ[p, 1] || (EqQ[n, 1] && IntegerQ[m])) && NeQ[m, -1
]

Rule 6161

Int[((a_.) + ArcTanh[(c_.)*(x_)]*(b_.))^(p_.)*((f_.)*(x_))^(m_)*((d_) + (e_.)*(x_)^2)^(q_.), x_Symbol] :> Dist
[d, Int[(f*x)^m*(d + e*x^2)^(q - 1)*(a + b*ArcTanh[c*x])^p, x], x] - Dist[c^2*(d/f^2), Int[(f*x)^(m + 2)*(d +
e*x^2)^(q - 1)*(a + b*ArcTanh[c*x])^p, x], x] /; FreeQ[{a, b, c, d, e, f, m}, x] && EqQ[c^2*d + e, 0] && GtQ[q
, 0] && IGtQ[p, 0] && (RationalQ[m] || (EqQ[p, 1] && IntegerQ[q]))

Rubi steps

\begin {align*} \int \frac {\left (1-a^2 x^2\right ) \tanh ^{-1}(a x)}{x} \, dx &=-\left (a^2 \int x \tanh ^{-1}(a x) \, dx\right )+\int \frac {\tanh ^{-1}(a x)}{x} \, dx\\ &=-\frac {1}{2} a^2 x^2 \tanh ^{-1}(a x)-\frac {\text {Li}_2(-a x)}{2}+\frac {\text {Li}_2(a x)}{2}+\frac {1}{2} a^3 \int \frac {x^2}{1-a^2 x^2} \, dx\\ &=-\frac {a x}{2}-\frac {1}{2} a^2 x^2 \tanh ^{-1}(a x)-\frac {\text {Li}_2(-a x)}{2}+\frac {\text {Li}_2(a x)}{2}+\frac {1}{2} a \int \frac {1}{1-a^2 x^2} \, dx\\ &=-\frac {a x}{2}+\frac {1}{2} \tanh ^{-1}(a x)-\frac {1}{2} a^2 x^2 \tanh ^{-1}(a x)-\frac {\text {Li}_2(-a x)}{2}+\frac {\text {Li}_2(a x)}{2}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]
time = 0.02, size = 60, normalized size = 1.25 \begin {gather*} -\frac {a x}{2}-\frac {1}{2} a^2 x^2 \tanh ^{-1}(a x)-\frac {1}{4} \log (1-a x)+\frac {1}{4} \log (1+a x)+\frac {1}{2} (-\text {PolyLog}(2,-a x)+\text {PolyLog}(2,a x)) \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[((1 - a^2*x^2)*ArcTanh[a*x])/x,x]

[Out]

-1/2*(a*x) - (a^2*x^2*ArcTanh[a*x])/2 - Log[1 - a*x]/4 + Log[1 + a*x]/4 + (-PolyLog[2, -(a*x)] + PolyLog[2, a*
x])/2

________________________________________________________________________________________

Maple [A]
time = 0.13, size = 69, normalized size = 1.44

method result size
derivativedivides \(-\frac {a^{2} x^{2} \arctanh \left (a x \right )}{2}+\arctanh \left (a x \right ) \ln \left (a x \right )-\frac {a x}{2}-\frac {\ln \left (a x -1\right )}{4}+\frac {\ln \left (a x +1\right )}{4}-\frac {\dilog \left (a x \right )}{2}-\frac {\dilog \left (a x +1\right )}{2}-\frac {\ln \left (a x \right ) \ln \left (a x +1\right )}{2}\) \(69\)
default \(-\frac {a^{2} x^{2} \arctanh \left (a x \right )}{2}+\arctanh \left (a x \right ) \ln \left (a x \right )-\frac {a x}{2}-\frac {\ln \left (a x -1\right )}{4}+\frac {\ln \left (a x +1\right )}{4}-\frac {\dilog \left (a x \right )}{2}-\frac {\dilog \left (a x +1\right )}{2}-\frac {\ln \left (a x \right ) \ln \left (a x +1\right )}{2}\) \(69\)
risch \(\frac {\left (-a x +1\right )^{2} \ln \left (-a x +1\right )}{4}-\frac {a x}{2}-\frac {\left (-a x +1\right ) \ln \left (-a x +1\right )}{2}+\frac {\dilog \left (-a x +1\right )}{2}-\frac {\left (a x +1\right )^{2} \ln \left (a x +1\right )}{4}+\frac {\left (a x +1\right ) \ln \left (a x +1\right )}{2}-\frac {\dilog \left (a x +1\right )}{2}\) \(83\)
meijerg \(-\frac {i \left (\frac {2 i a x \polylog \left (2, \sqrt {a^{2} x^{2}}\right )}{\sqrt {a^{2} x^{2}}}-\frac {2 i a x \polylog \left (2, -\sqrt {a^{2} x^{2}}\right )}{\sqrt {a^{2} x^{2}}}\right )}{4}-\frac {i \left (-2 i x a +2 i \left (-a x +1\right ) \left (a x +1\right ) \arctanh \left (a x \right )\right )}{4}\) \(85\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((-a^2*x^2+1)*arctanh(a*x)/x,x,method=_RETURNVERBOSE)

[Out]

-1/2*a^2*x^2*arctanh(a*x)+arctanh(a*x)*ln(a*x)-1/2*a*x-1/4*ln(a*x-1)+1/4*ln(a*x+1)-1/2*dilog(a*x)-1/2*dilog(a*
x+1)-1/2*ln(a*x)*ln(a*x+1)

________________________________________________________________________________________

Maxima [B] Leaf count of result is larger than twice the leaf count of optimal. 89 vs. \(2 (36) = 72\).
time = 0.26, size = 89, normalized size = 1.85 \begin {gather*} -\frac {1}{4} \, a {\left (2 \, x + \frac {2 \, {\left (\log \left (a x + 1\right ) \log \left (x\right ) + {\rm Li}_2\left (-a x\right )\right )}}{a} - \frac {2 \, {\left (\log \left (-a x + 1\right ) \log \left (x\right ) + {\rm Li}_2\left (a x\right )\right )}}{a} - \frac {\log \left (a x + 1\right )}{a} + \frac {\log \left (a x - 1\right )}{a}\right )} - \frac {1}{2} \, {\left (a^{2} x^{2} - \log \left (x^{2}\right )\right )} \operatorname {artanh}\left (a x\right ) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((-a^2*x^2+1)*arctanh(a*x)/x,x, algorithm="maxima")

[Out]

-1/4*a*(2*x + 2*(log(a*x + 1)*log(x) + dilog(-a*x))/a - 2*(log(-a*x + 1)*log(x) + dilog(a*x))/a - log(a*x + 1)
/a + log(a*x - 1)/a) - 1/2*(a^2*x^2 - log(x^2))*arctanh(a*x)

________________________________________________________________________________________

Fricas [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((-a^2*x^2+1)*arctanh(a*x)/x,x, algorithm="fricas")

[Out]

integral(-(a^2*x^2 - 1)*arctanh(a*x)/x, x)

________________________________________________________________________________________

Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} - \int \left (- \frac {\operatorname {atanh}{\left (a x \right )}}{x}\right )\, dx - \int a^{2} x \operatorname {atanh}{\left (a x \right )}\, dx \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((-a**2*x**2+1)*atanh(a*x)/x,x)

[Out]

-Integral(-atanh(a*x)/x, x) - Integral(a**2*x*atanh(a*x), x)

________________________________________________________________________________________

Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((-a^2*x^2+1)*arctanh(a*x)/x,x, algorithm="giac")

[Out]

integrate(-(a^2*x^2 - 1)*arctanh(a*x)/x, x)

________________________________________________________________________________________

Mupad [F]
time = 0.00, size = -1, normalized size = -0.02 \begin {gather*} -\int \frac {\mathrm {atanh}\left (a\,x\right )\,\left (a^2\,x^2-1\right )}{x} \,d x \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(-(atanh(a*x)*(a^2*x^2 - 1))/x,x)

[Out]

-int((atanh(a*x)*(a^2*x^2 - 1))/x, x)

________________________________________________________________________________________